package com.cainaer.product.api;

import com.cainaer.product.api.factory.RemoteProductFallbackFactory;
import feign.Headers;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;
import com.cainaer.common.core.constant.ServiceNameConstants;

import java.util.List;


/**
 *
 * 评论服务
 * @author cainaer
 */
@FeignClient(contextId = "remoteProductService", value = ServiceNameConstants.SYSTEM_PRODUCT, fallbackFactory = RemoteProductFallbackFactory.class)
public interface RemoteProductService
{
    /**
     * 通过商商品ID查询这个这个商品的平均评价级别
     *
     * @param productId 商品ID
     * @return
     */
    @GetMapping("/comment/selectCommentAvgLevelByProductId")
    Integer selectCommentAvgLevelByProductId(@RequestParam("productId") Long productId);



}
